package com.c.ctgproject.ui.doorkeeper

import com.c.ctgproject.R
import com.c.ctgproject.base.BaseActivity
import com.c.ctgproject.ui.doorkeeper.car.CarWaitActivity
import com.c.ctgproject.ui.doorkeeper.material.DoorkeeperMaterialActivity
import com.c.ctgproject.ui.doorkeeper.part.DoorkeeperPartActivity
import com.c.ctgproject.utils.exitApp
import com.c.ctgproject.utils.showPopupWindow
import com.c.ctgproject.utils.startActivity
import kotlinx.android.synthetic.main.activity_door_keeper_home.*

/**
 *作者:LiBW
 *创建日期: 2020/9/10
 *描述:门卫选择功能页面 门卫 页面
 */
class DoorKeeperHome : BaseActivity() {
    override fun getLayout() = R.layout.activity_door_keeper_home

    override fun event() {
        changeTransparentStatusBar()
    }

    override fun click() {
        //待入场车辆
        mCarWaitLL.setOnClickListener {
            startActivity<CarWaitActivity>()
        }
        //配件出场
        mPartOutLL.setOnClickListener {
            startActivity<DoorkeeperPartActivity>()
        }
        //物料出场
        mMaterialOutLL.setOnClickListener {
            startActivity<DoorkeeperMaterialActivity>()
        }
        //设置和角色切换
        mSettingIV.setOnClickListener {
            showPopupWindow(it)
        }
    }

    override fun onBackPressed() {
        exitApp()
    }

}